package com.wzy.spring2.config;

import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

/**
 * @author Weizhengyun
 * @desc
 * @date 2022/12/17 上午10:53
 */
@Configuration
public class ThreadPoolConfig {

    @Bean
    @Qualifier("threadPool")
    public ExecutorService obtainThreadPool() {
        return Executors.newFixedThreadPool(15);
    }
}
